package com.blog.webSocket.domain;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

/**
 * @author 任浩
 * @version 1.0
 */

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@TableName("chat_message")
public class ChatMessage {

    @TableId
    private Integer id;

//    @TableField(value = "link_id")
//    private Integer linkId;

    @TableField(value = "from_user")
    private String fromUser;

    @TableField(value = "to_user")
    private String toUser;

    //内容
    @TableField(value = "content")
    private String content;

    @TableField(value = "send_time")
    private LocalDateTime sendTime;

    @TableField(value = "type")
    private Integer type;

    @TableField(value = "is_latest")
    private Integer isLatest;
}
